home *** CD-ROM | disk | FTP | other *** search
- Path: bmtlh10.bnr.ca!news
- From: John Hickin <hickin@bnr.ca>
- Newsgroups: comp.lang.c++
- Subject: Re: is <string.h> standard in c++?
- Date: 4 Mar 1996 19:04:58 GMT
- Organization: Bell Northern Research
- Message-ID: <4hfesq$hsf@bmtlh10.bnr.ca>
- References: <313B0603.1CD@dal.ca>
- NNTP-Posting-Host: bmtlh520.bnr.ca
- Mime-Version: 1.0
- Content-Type: text/plain; charset=us-ascii
- Content-Transfer-Encoding: 7bit
- X-Mailer: Mozilla 1.1 (X11; I; HP-UX A.09.05 9000/715)
- X-URL: news:313B0603.1CD@dal.ca
-
- #include <string.h>
-
- I can't comment on the 2.7.2 implementation but I have experience with the
- 2.7.1 implementation:
-
- 1. In my opinion it violates the standard. First, reserve() is an empty
- function. Second, I believe that the wording of the standard limits any
- reference counted approach to the cases of 0 or 1 references (carefully read
- the
- description of the copy constructor and assignment operator and see if you
- agree with me). In contrast the gnu 2.7.1 implementation seems to allow up to
- 255 references.
-
- 2. See an earlier post to comp.std.c++ by James Kanze on the difficulties of
- implementing copy-on-write semantics (also used in the gnu implementation) with
- respect to the reserve() function.
-
-
- This implementation may have incompatibilities with the standard but I feel
- that it is a good place to start getting practice.
-
- --
- John Hickin Nortel Technology, Montreal, Quebec
- (514) 765-7924 hickin@bnr.ca
-
-